package cn.tutu.blockchain.contact.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import cn.tutu.blockchain.contact.dao.ContactDao;
import cn.tutu.blockchain.contact.entity.Contact;
import cn.tutu.blockchain.contact.service.ContactService;

@Service
@Transactional
public class ContactServiceImpl implements ContactService {

	@Autowired
	private ContactDao contactDao;

	@Override
	public void create(Contact addrList) {
		contactDao.insert(addrList);
	}

	@Override
	public List<Contact> getContact(String sourceUserId) {
		// TODO Auto-generated method stub
		return contactDao.findBySourceUser(sourceUserId);
	}

}
